#ifndef _FENGINE_PRIMITIVE_LINE_LIST
#define _FENGINE_PRIMITIVE_LINE_LIST

#include <vector>
#include "CoreEngine.h"
#include "FEngineType.h"
#include "Primitive.h"
#include "ColorRGB.h"

namespace FEngine
{
	/**
	 * Draw a list of segment.
	 */
	class PrimitiveLineList : public Primitive
	{

		public:

			/**
			 * Constructor.
			 */
			PrimitiveLineList();
			virtual ~PrimitiveLineList();
			
			/**
			 * Add a segment to the line list.
			 * Send an FException if the generate() method has already been called.
			 * @param _a First extremity of the line.
			 * @param _b First extremity of the line.
			 * @param _color Color of the segment.
			 */
			void addLine(const Vector3& _a, const Vector3& _b);

			/**
			 * Generate the mesh based on the line value created by addLine().
			 */
			void generate();


		private:
			
			std::vector<Vector3>		mVerticesVector;
			std::vector<unsigned int>	mIndexesVector;
	};

} // namespace FEngine

#endif
